/*
 * @Author: Sun //下拉组件
 * @Date: 2019-7-12 16:35:59
 */
import {getDiscList} from '@/models/deon.js'; //首页请求方式
import Vue from 'vue'
import axios from 'axios'

const state={
    textData:[],
		radionButton:""
}
const actions={
  getRemark({commit,rootState},type){//请求测试数据
    let url ="https://api.mlwei.com/music/api/?key=523077333&cache=1&type=so&id=%E6%B5%81%E8%A1%8C&size=hq"
    getDiscList({url}).then((res)=>{
      commit("getPlace",res.data.Body)
    })
  }
}

const mutations={
  getPlace(state, data){//设置数据
    state.textData=data
    localStorage.setItem('vdeonData',JSON.stringify(state.textData))
  },
	setUpdata(state, data){//设置数据
	
		state.radionButton=data.data
	}
}

export default {
  state,
/*  getters,*/
  actions,
  mutations,
  namespaced: true
}
